package com.trippartner.client.map.view;

import com.google.gwt.dom.client.Style.Unit;
import com.google.gwt.user.client.ui.Composite;
import com.google.gwt.user.client.ui.HTML;
import com.google.gwt.user.client.ui.HasVerticalAlignment;
import com.google.gwt.user.client.ui.HorizontalPanel;
import com.google.gwt.user.client.ui.SimplePanel;
import com.google.gwt.user.client.ui.StackLayoutPanel;
import com.google.gwt.user.client.ui.VerticalPanel;
import com.google.gwt.user.client.ui.Widget;
import com.trippartner.client.map.presenter.GeoPointDetailsPresenter.Display;
import com.google.gwt.user.client.ui.FlowPanel;
import com.google.gwt.user.client.ui.Grid;
import com.google.gwt.user.client.ui.Label;
import com.google.gwt.user.client.ui.TextBox;
import com.google.gwt.user.datepicker.client.DateBox;
import com.google.gwt.user.client.ui.ListBox;
import com.google.gwt.user.client.ui.FlexTable;
import com.google.gwt.user.client.ui.Button;

public class GeoPointDetailsView extends Composite implements Display {

	public GeoPointDetailsView() {

		createContents();
	}

	private void createContents() {

		StackLayoutPanel stackLayoutPanel = new StackLayoutPanel(Unit.EM);

		HorizontalPanel OUPanel = new HorizontalPanel();
		HorizontalPanel QUANDPanel = new HorizontalPanel();
		HorizontalPanel COMMENTPanel = new HorizontalPanel();
		HorizontalPanel AVECQUIPanel = new HorizontalPanel();

		stackLayoutPanel.add(OUPanel, new HTML("OU"), 2.0);
		
		Grid grid = new Grid(1, 4);
		grid.setBorderWidth(1);
		grid.setCellSpacing(1);
		grid.setCellPadding(1);
		OUPanel.add(grid);
		grid.setSize("409px", "27");
		
		Label lblNewLabel = new Label("Longitude");
		grid.setWidget(0, 0, lblNewLabel);
		
		TextBox textBox = new TextBox();
		grid.setWidget(0, 1, textBox);
		
		Label lblNewLabel_1 = new Label("Latitude");
		grid.setWidget(0, 2, lblNewLabel_1);
		
		TextBox textBox_1 = new TextBox();
		grid.setWidget(0, 3, textBox_1);
		
		DateBox dateBox = new DateBox();
		QUANDPanel.add(dateBox);
		stackLayoutPanel.add(QUANDPanel, new HTML("QUAND"), 2.0);
		
		ListBox listBox = new ListBox();
		COMMENTPanel.add(listBox);
		listBox.setVisibleItemCount(5);
		stackLayoutPanel.add(COMMENTPanel, new HTML("COMMENT"), 2.0);
		stackLayoutPanel.add(AVECQUIPanel, new HTML("AVEC QUI"), 2.0);
		
		FlexTable flexTable = new FlexTable();
		AVECQUIPanel.add(flexTable);
		
		Label lblNewLabel_2 = new Label("New label");
		flexTable.setWidget(0, 0, lblNewLabel_2);
		
		Button btnNewButton = new Button("add FB people");
		flexTable.setWidget(0, 1, btnNewButton);

		initWidget(stackLayoutPanel);
	}

}
